I am trying to find the status of the called number using Dial status. I am creating a "call file" where I am defining the channel as local channel. you can see the code below for the call file. Then, I have written the context and extensions which has a "dial plan". You can see the code below for the extensions.conf. Now, when i placed the call file in /var/spool/outgoing I am unable to view the dial status and I am facing some errors. Can any one please help me on this issue.
Here is the detailed explanation of my problem.
My call file is:
Channel: LOCAL/123@newamar/n
CallerID: 456456
MaxRetries: 0
RetryTime: 9
WaitTime: 12
Context: newamar
Extension: 124
Priority: 1
Setvar: SOUND=/var/www/push/sound/CallMeBackUS
Setvar: DESTINATION=7865210317
Setvar: OPERATOR=vitel-outbound
my extensions.conf file is:
[newamar]
exten => 123,1,Dial(SIP/${DESTINATION}@${OPERATOR})
exten => 123,n,Goto(s-${DIALSTATUS},1)
exten => s-NOANSWER,1,NoOp(no answer)
exten => s-CONGESTION,1,NoOp(congestion)
exten => s-CANCEL,1,NoOp(cancel)
exten => s-BUSY,1,NoOp(Busy)
exten => s-ANSWER,1,Playback(${SOUND})
exten => s-ANSWER,n,Hangup
exten => 123,1,NoOp(${DIALSTATUS})
exten => 123,n,Hangup
When I placed my call file in /var/spool/outgoing i am getting the following description in my console:
-- Attempting call on LOCAL/123@newamar/n for 124@newamar:1 (Retry 1)
-- Executing [123@newamar:1] Dial("Local/123@newamar-8e8f,2", "SIP/7865210317@vitel-outbound") in new stack
-- Called 7865210317@vitel-outbound
-- SIP/vitel-outbound-006648b0 is ringing
-- SIP/vitel-outbound-006648b0 is making progress passing it to Local/123@newamar-8e8f,2
-- SIP/vitel-outbound-006648b0 answered Local/123@newamar-8e8f,2
> Channel Local/123@newamar-8e8f,1 was answered.
== Starting Local/123@newamar-8e8f,1 at newamar,124,1 failed so falling back to exten 's'
== Starting Local/123@newamar-8e8f,1 at newamar,s,1 still failed so falling back to context 'default'
[Dec 30 14:19:39] WARNING[2899]: pbx.c:2470 __ast_pbx_run: Channel 'Local/123@newamar-8e8f,1' sent into invalid extension 's' in context 'default', but no invalid handler
[Dec 30 14:19:39] NOTICE[2899]: pbx_spool.c:365 attempt_thread: Call completed to LOCAL/123@newamar/n
== Spawn extension (newamar, 123, 1) exited non-zero on 'Local/123@newamar-8e8f,2'